package com.lam.code.service;

import com.alicp.jetcache.anno.CacheType;
import com.alicp.jetcache.anno.Cached;
import com.lam.code.base.BaseService;
import com.lam.code.entity.User;

import java.util.List;

/**
 * @author lam
 * @description TODO
 * @date 2019/9/29 22:43
 */
public interface HelloService extends BaseService<User> {

    void saveUser(User user);

    /**
     * 獲取用戶
     * @return
     */
    @Cached(name="HelloService.getUser", expire = 5, cacheType= CacheType.LOCAL)
    List<User> getUser();


    List<User> getUser2();
}
